import {
  TabNavigator
} from 'react-navigation'

//底部导航页面
import HomeTabs from '../StackNavigator/firstnav';
import MessageTabs from '../StackNavigator/secondnav';
import ToosTabs from '../StackNavigator/threenav';
import MyTabs from '../StackNavigator/fournav';

//设置底部导航
const TabNav = TabNavigator({
  HomeTab: {
    screen: HomeTabs,
    title: '首页'
  },
  MessageTab: {
    screen: MessageTabs,
  },
  ToolTab: {
    screen: ToosTabs,
    path: 'toos',
  },
  MyTab: {
    screen: MyTabs,
  },
}, {
  tabBarPosition: 'bottom',
  animationEnabled: false,
  swipeEnabled: false,
  tabBarOptions: {
    showIcon: true, //显示图片
    activeTintColor: '#e62e4c', // 文字和图片选中颜色
    inactiveTintColor: '#666666', // 文字和图片默认颜色
    showLabel: true, //显示底部标签
    indicatorStyle: {
      height: 0
    }, // android 
    labelStyle: {
      fontSize: 12,
    },
    tabStyle: {
      //width: 100,
      height: 70,
    },
    iconStyle: {
      width: 29,
      height: 29,
    },
    style: {
      backgroundColor: '#ffffff',
      borderTopWidth: 0.1,
      borderTopColor: '#dddddd',
    },
  }
});

export default TabNav;